package com.sailor.excel.apiclient;

import com.sailor.excel.httpclient.annotation.AutoCache;
import com.sailor.excel.httpclient.annotation.AutoGet;
import com.sailor.excel.httpclient.annotation.AutoHttpClient;
import com.sailor.excel.util.BaseModel;
import com.sailor.excel.vo.AircraftBasicInfoResult;

import java.util.concurrent.CompletableFuture;

@AutoHttpClient
public interface AutoClient {
    @AutoGet(
            dev = "http://carservice2.yz.test.autohome.com.cn/category/getSeriesInfoById?buId=2&seriesId=${seriesId}",
            beta = "http://carservice2.yz.test.autohome.com.cn/category/getSeriesInfoById?buId=2&seriesId=${seriesId}",
            online = "http://carservice2.yz.test.autohome.com.cn/category/getSeriesInfoById?buId=2&seriesId=${seriesId}"
    )
    @AutoCache(liveTime = 60 * 10, effectiveTime = 60 * 10)
    CompletableFuture<BaseModel<AircraftBasicInfoResult>> getBasicInfoForHomePage(int seriesId);
}
